<template>
	<div>
		<keep-alive>
			<router-view v-if="$route.meta.keepAlive"></router-view>
		</keep-alive>
			<router-view v-if="!$route.meta.keepAlive && isRouterAlive"></router-view>
	</div>
</template>

<script>
	export default{
		provide(){
			return {
				reload:this.reload
			}
		},
		data(){
			return {
				isRouterAlive:true
			}
		},
		methods: {
			reload() {
				this.isRouterAlive = false
				this.$nextTick(()=>{
					this.isRouterAlive = true
				})
			}
		},
	}
</script>

<style lang="less">
	@import './style/public';
	@import './style/home';
	@import './style/login';
	@import './style/order';
</style>
